#include<stdio.h>
void minmax(int *a,int len,int *min,int *max);
int main(){
	int a[] = {1,4,5,8,7,45,12,63,56,};
	int min,max;
	printf("main sizeof(a)=%lu\n",sizeof(a));
	printf("main a=%p\n",a);
	minmax(a,sizeof(a)/sizeof(a[0]),&min,&max);
	printf("min=%d\t max=%d\n",min,max);
	printf("a[0]=%d\n",a[0]);
	int *p = &a[2];
	printf("*p=%d\n",*p);
	printf("p[0]=%d\n",p[0]);
	printf("*a=%d\n",*a);
	//int b[]-->int *const b;
	//int *q = a;


    return 0;
}
void minmax(int *a,int len,int *min,int *max){
	printf("minmax sizeof(a[0])=%d\n",sizeof(a));
	printf("minmax a=%p\n",a);
	*max=*min=a[0];
	a[0]=150;
	int i;
	for(i=0;i<len;i++){
		if(a[i]>*max){
			*max=a[i];
		}
		if(a[i]<*min){
			*min=a[i];
		}
	}
	
}
